// Convert fillup units per distance (i.e n liters per 100 km)
// to distance per fillup unit (e.g. m km per 1 L)
exports.fillupUnitsPerDistanceToDistancePerFillupUnit = function(n) {
	if(n) {
		var m = (100 / n);
		return m.toFixed(2);
	}
}

// Proper formatting of fillup units per distance, e.g. 1.23 (L per 100 km)
exports.fillupUnitsPerDistanceFormat = function(n) {
	if(n) {
		return n.toFixed(2);
	}
}

exports.getCurrentCurrency = function() {
	var returnedCurrency = '';
	
	var currentLocale = Titanium.Locale.getCurrentLocale();
	if(currentLocale) {
		returnedCurrency = Titanium.Locale.getCurrencyCode(currentLocale);
	}
	
	return returnedCurrency;
}
